<?php 
    namespace Home\Model;
    use Think\Model;
    class FriendlyModel extends Model{
       
        // //自动验证
        protected $_validate = array(
          array('fname','require','网站名不能为空',1,'regex',3),
          array('fname','1,20','你的网站名太长了',1,'length',3),
          array('fpath','require','网址名不能为空',1,'regex',3),
          array('fpath','1,120','你的网址名太长了',1,'length',3),
        );
    }